package com.cashmama.market.api.application.controller.order.repay.request;

import com.cashmama.market.api.infras.exception.ApplicationException;
import com.fqgj.common.api.ParamsObject;
import com.fqgj.common.utils.CollectionUtils;

import java.util.List;

/**
 * @program: market-api
 * @description
 * @author: frank
 * @create: 2019-12-26 11:35
 **/
public class RepayStatusRequest extends ParamsObject {

    private List<String> billNos;

    public List<String> getBillNos() {
        return billNos;
    }

    public RepayStatusRequest setBillNos(List<String> billNos) {
        this.billNos = billNos;
        return this;
    }

    @Override
    public void validate() {
        if(CollectionUtils.isEmpty(billNos)){
            throw new ApplicationException("billNos can not be empty");
        }
    }
}
